<!-- 新增数据字典模态框  -->
<div class="modal-header">
    <button type="button" class="close" data-dismiss="modal" aria-hidden="true" ng-click="dialog.dismiss()">&times;
    </button>
    <h1 class="modal-title" translate="{{vm.title}}"></h1>
</div>
<div class="modal-body">
    <ng-form name="dictAddForm" class="form-horizontal form-validation">
        <div class="panel-body">
            <div class="row">
                <!--字典类型-->
                <div class="col-md-6">
                    <div class="form-group">
                        <label class="col-md-3 control-label">
                            <span class="text-danger">*</span>
                            <span translate="dict.category"></span>
                        </label>
                        <div class="col-md-9">
                            <ui-select ng-model="vm.categoryDictionary" theme="bootstrap" ng-disabled="vm.disable">
                                <ui-select-match>
                                    {{$select.selected.content}}
                                </ui-select-match>
                                <ui-select-choices repeat="c in vm.categories | filter: $select.search">
                                    <small>
                                        <span ng-bind-html="c.content | highlight: $select.search"></span>
                                    </small>
                                </ui-select-choices>
                            </ui-select>
                        </div>
                    </div>
                </div>
                <!--语言-->
                <div class="col-md-6">
                    <div class="form-group">
                        <label class="col-md-3 control-label">
                            <span class="text-danger">*</span>
                            <span translate="lang.name"></span>
                        </label>
                        <div class="col-md-9">
                            <select class="form-control" name="category" disabled>
                                <option translate="{{i18n.langDesc}}"></option>
                            </select>
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <!--编号 Code-->
                <div class="col-md-6">
                    <div class="form-group">
                        <label class="col-md-3 control-label">
                            <span class="text-danger">*</span>
                            <span translate="dict.code"></span>
                        </label>
                        <div class="col-md-9">
                            <input type="text" name="code" class="form-control"
                                   ng-model="vm.dict.code" id="numberID" maxlength="32" required
                                   uib-tooltip="{{'common.op.remind1' | translate}}"/>
                        </div>
                    </div>
                </div>
                <!--数值 Value-->
                <div class="col-md-6">
                    <div class="form-group">
                        <label class="col-md-3 control-label">
                            <span class="text-danger">*</span>
                            <span translate="dict.value"></span>
                        </label>
                        <div class="col-md-9">
                            <input type="number" name="value" class="form-control"
                                   ng-model="vm.dict.value" id="valueID" maxlength="10" required
                                   uib-tooltip="{{app.getMessage('common.op.remind14',[1,10])}}"/>
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <!--名称-->
                <div class="col-md-6">
                    <div class="form-group ">
                        <label class="col-md-3 control-label">
                            <span class="text-danger">*</span>
                            <span translate="dict.content"></span>
                        </label>
                        <div class="col-md-9">
                            <input type="text" name="id" class="form-control"
                                   ng-model="vm.dict.content" maxlength="32" required
                                   uib-tooltip="{{'common.op.remind1' | translate}}"/>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </ng-form>
    <div class="panel-footer text-right bg-light lter">
        <button type="button" class="btn btn-default" translate="common.cancel" ng-click="dialog.dismiss()"></button>
        <button type="button" class="btn btn-primary" ng-click="vm.save()"
                ng-disabled="dictAddForm.$invalid" translate="common.confirm"></button>
    </div>
</div>